#include "headfiles.h"

using namespace std;

bool shuffleDeck(int *array, int n) {
    if (array == NULL ||
        n <= 0) {
        cout << "Invalid input arguments!" << endl;
        return false;
    }

    int i, tmp;
    for (i = 0; i < n; i++) {
        int sel = rand() % (n - i) + i;
        tmp = array[i];
        array[i] = array[sel];
        array[sel] = tmp;
    }

    return true;
}

